<?php

namespace app\model;

use think\Model;
use think\facade\Db;
use app\utils\Utils;

class Log extends Model
{
    protected $table = 'site_log';
    static public function WriteData($data)
    {
        $data['ip'] = Utils::getIp();
        $data['time'] = time();

        return self::strict(false)->insertGetId($data);
    }
}
